﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using Xroad.Eu.Xsd.Identifiers;

namespace Xtee.CodeDom
{
    public class ServiceInfo
    {
        public ServiceInfo()
        {
            
        }
        public ServiceInfo(string xRoadObjectType, string xroadInstance, string memberClass, string memberCode, string subsystemCode)
        {
            if (!string.IsNullOrEmpty(xRoadObjectType))
                ObjectType=new XRoadObjectType(xRoadObjectType);

            XroadInstance = xroadInstance == "" ? null: xroadInstance;
            MemberClass = memberClass == "" ? null : memberClass;
            MemberCode = memberCode == "" ? null : memberCode;
            SubsystemCode = subsystemCode == "" ? null : subsystemCode;
        }
        public XRoadObjectType ObjectType { get; }
        public string XroadInstance { get; }
        public string MemberClass { get; }
        public string MemberCode { get; }
        public string SubsystemCode { get;}
    }
}
